package cn.tx.zhujie;

import java.lang.reflect.Field;

/**
 * @Package: cn.tx
 * @Description: 类作用描述
 * @Author Mxb
 * @CreateDate 2020/10/17 9:23
 * @Version 1.0
 */
public class ZhuJieTest {
    public static void main(String[] args) {
        Class<ZhuJieShiYong> zhuJieShiYong = ZhuJieShiYong.class;
        ZhuJie annotation = zhuJieShiYong.getAnnotation(ZhuJie.class);

        if(annotation!=null){
            System.out.println("content: "+annotation.content());
            System.out.println("num: "+annotation.num());
        }


        Class<ZhuJieShiYong> zhuJieShiYong1 = ZhuJieShiYong.class;
        Field[] annotation1 = zhuJieShiYong1.getDeclaredFields();

        for(Field f : annotation1){

        }

        if(annotation!=null){
            System.out.println("content: "+annotation.content());
            System.out.println("num: "+annotation.num());
        }
    }
}
